#ifndef SHADER_H
#define SHADER_H

#include <stdlib.h>
#include <stdio.h>
#include <string.h>

#if defined(__APPLE__)
#	include <OpenGL/gl.h>
#else
#	include <GL/gl.h>
#endif

typedef struct rat_shader
{
	int dumped;
	GLuint program_handle;
	GLuint vert,frag;
	FILE *log;
} rat_shader;

#ifdef __cplusplus
extern "C" {
#endif

rat_shader *rat_load_shader(char *dir,char *name,FILE *log_file);
void rat_destroy_shader(rat_shader *shader);
void rat_apply_shader(rat_shader *shader);

#ifdef __cplusplus
}
#endif

#endif

